package com.quanyan.stadiumScheduler.biz;

import com.quanyan.stadiumScheduler.entity.*;
import com.quanyan.stadiumScheduler.entity.vo.VDefinedGameSchedule;

import java.util.List;

/**
 * Created by xiao.lai on 16/5/26.
 */
public interface BizGameSystemDao {

    /**
     * 查询 TbGameEvent,根据id
     *
     * */
    List<TbGameRound> selectTbGameRoundByGameEventId(Integer gameEventId);

    /**
     * 查询 TbGameSchedule,根据gameRoundId
     *
     * */
    List<TbGameSchedule> selectTbGameScheduleByGameRoundId(Integer gameRoundId, Integer pageNum, Integer pageSize);

    /**
     * 查询赛事下的用户,根据isDelete状态来区分,按score排序
     * @param gameEventId
     * @return
     */
    List<TbGameEventTeam> selectTbGameEventTeamByGameEventId(Integer gameEventId, Byte isDelete);

    /**
     * 根据clubId 和 gameEventId后去代表队信息
     *
     * @return
     */
    List<TbGameClubTeamUser>  queryTbGameClubTeamUserByClubId(Integer gameEventId, Integer clubId);

    /**
     * 自定义查询
     *
     * */
    List<VDefinedGameSchedule> selectVDefinedGameScheduleByGameRoundId(Integer gameRoundId, Integer pageNum, Integer pageSize);
    /**
     * 录入
     *
     * */
    void insertSelectiveUserGameSchedule(TbUserGameSchedule userGameSchedule);

    /**
     * 根据id更新数据
     *
     * */
    void updateSelectiveUserGameSchedule(TbUserGameSchedule userGameSchedule, TbUserGameScheduleExample example);

    /**
     * 根据id查询记录
     *
     * */
    TbGameSchedule selectGameSchedule(Integer id);

}